package com.fable.biz.operate;

import com.fable.biz.operate.dto.CustomerDTO;
import com.fable.biz.operate.query.CustomerQueryCondition;
import com.fable.dal.model.CustomerDO;

import java.util.List;

/**
 * Created by weishuai on 18/4/7.
 */
public interface CustomerService {

    /**
     * 添加或修改客户信息
     * @param customerDTO
     * @return
     */
    int addOrModifyCustomer(CustomerDTO customerDTO);

    /**
     * 根据主键查询客户信息
     *
     * @param id
     * @return
     */
    CustomerDO getById(Integer id);

    /**
     * 获取客户信息
     *
     * @param condition
     * @return
     */
    List<CustomerDTO> findCustomerList(CustomerQueryCondition condition);


    /**
     * 逻辑删除客户信息
     *
     * @param customerDTO 客户类型
     * @return
     */
    int delCustomer(CustomerDTO customerDTO);

    /**
     * 获取私有客户的数量
     * @param theirBy
     * @return
     */
    int priPriCustomer(String theirBy);

}
